package sample.templates;

import java.util.Enumeration;
import java.util.Vector;

public class TrashBinSet {
	private TypedBin[] binSet = { new AluminumBin(), new CardboardBin(),
			new GlassBin(), new PaperBin() };

	public void sortInfoBins(Vector bin) {
		Enumeration e = bin.elements();
		while (e.hasMoreElements()) {
			TypeBinMember t = (TypeBinMember) e.nextElement();
			if (!t.addToBin(binSet))
				System.out.println("Couldn't add" + t);
		}
	}

	public TypedBin[] binSet() {
		return binSet;
	}
}
